// 讲师管理api
import request from '@/utils/request'

const api_name = '/eduservice/teacher'
export default{

    // 请求后台讲师分页列表
    getPageList(page,limit,teacherQuery){
        return request({
            url: `${api_name}/${page}/${limit}`,
            method:'post',
            data:teacherQuery
        })
    },

    // 获取所有讲师列表
    getList(){
        return request({
            url:`${api_name}/findAll`,
            method:'get'
        })
    },

    // 删除讲师
    removeById(id){
        return request({
            url:`${api_name}/${id}`,
            method:'delete'
        })
    },

    // 添加讲师
    save(eduTeacher){
        return request({
            url: `${api_name}/insert`,
            method:'post',
            data:eduTeacher
        })
    },

    // 根据id查找讲师信息
    getById(id){
        return request({
            url: `${api_name}/${id}`,
            method:'get'
        })
    },

    // 修改讲师
    updateTeacherInfo(eduTeacher){
        return request({
            url: `${api_name}/updateById/${eduTeacher.id}`,
            method:'post',
            data:eduTeacher
        })
    }


}